package yannan.voiplock4ble.bean;

import java.util.Map;

import org.greenrobot.greendao.AbstractDao;
import org.greenrobot.greendao.AbstractDaoSession;
import org.greenrobot.greendao.database.Database;
import org.greenrobot.greendao.identityscope.IdentityScopeType;
import org.greenrobot.greendao.internal.DaoConfig;

import yannan.voiplock4ble.bean.LocalDBTime;
import yannan.voiplock4ble.bean.LockBean;
import yannan.voiplock4ble.bean.LockKeyBean;
import yannan.voiplock4ble.bean.LockKeyTemp;
import yannan.voiplock4ble.bean.LockRecordBean;
import yannan.voiplock4ble.bean.PwdKeyBean;
import yannan.voiplock4ble.bean.UserAccount;
import yannan.voiplock4ble.bean.UserBean;
import yannan.voiplock4ble.bean.VeinKeyBean;

import yannan.voiplock4ble.bean.LocalDBTimeDao;
import yannan.voiplock4ble.bean.LockBeanDao;
import yannan.voiplock4ble.bean.LockKeyBeanDao;
import yannan.voiplock4ble.bean.LockKeyTempDao;
import yannan.voiplock4ble.bean.LockRecordBeanDao;
import yannan.voiplock4ble.bean.PwdKeyBeanDao;
import yannan.voiplock4ble.bean.UserAccountDao;
import yannan.voiplock4ble.bean.UserBeanDao;
import yannan.voiplock4ble.bean.VeinKeyBeanDao;

// THIS CODE IS GENERATED BY greenDAO, DO NOT EDIT.

/**
 * {@inheritDoc}
 * 
 * @see org.greenrobot.greendao.AbstractDaoSession
 */
public class DaoSession extends AbstractDaoSession {

    private final DaoConfig localDBTimeDaoConfig;
    private final DaoConfig lockBeanDaoConfig;
    private final DaoConfig lockKeyBeanDaoConfig;
    private final DaoConfig lockKeyTempDaoConfig;
    private final DaoConfig lockRecordBeanDaoConfig;
    private final DaoConfig pwdKeyBeanDaoConfig;
    private final DaoConfig userAccountDaoConfig;
    private final DaoConfig userBeanDaoConfig;
    private final DaoConfig veinKeyBeanDaoConfig;

    private final LocalDBTimeDao localDBTimeDao;
    private final LockBeanDao lockBeanDao;
    private final LockKeyBeanDao lockKeyBeanDao;
    private final LockKeyTempDao lockKeyTempDao;
    private final LockRecordBeanDao lockRecordBeanDao;
    private final PwdKeyBeanDao pwdKeyBeanDao;
    private final UserAccountDao userAccountDao;
    private final UserBeanDao userBeanDao;
    private final VeinKeyBeanDao veinKeyBeanDao;

    public DaoSession(Database db, IdentityScopeType type, Map<Class<? extends AbstractDao<?, ?>>, DaoConfig>
            daoConfigMap) {
        super(db);

        localDBTimeDaoConfig = daoConfigMap.get(LocalDBTimeDao.class).clone();
        localDBTimeDaoConfig.initIdentityScope(type);

        lockBeanDaoConfig = daoConfigMap.get(LockBeanDao.class).clone();
        lockBeanDaoConfig.initIdentityScope(type);

        lockKeyBeanDaoConfig = daoConfigMap.get(LockKeyBeanDao.class).clone();
        lockKeyBeanDaoConfig.initIdentityScope(type);

        lockKeyTempDaoConfig = daoConfigMap.get(LockKeyTempDao.class).clone();
        lockKeyTempDaoConfig.initIdentityScope(type);

        lockRecordBeanDaoConfig = daoConfigMap.get(LockRecordBeanDao.class).clone();
        lockRecordBeanDaoConfig.initIdentityScope(type);

        pwdKeyBeanDaoConfig = daoConfigMap.get(PwdKeyBeanDao.class).clone();
        pwdKeyBeanDaoConfig.initIdentityScope(type);

        userAccountDaoConfig = daoConfigMap.get(UserAccountDao.class).clone();
        userAccountDaoConfig.initIdentityScope(type);

        userBeanDaoConfig = daoConfigMap.get(UserBeanDao.class).clone();
        userBeanDaoConfig.initIdentityScope(type);

        veinKeyBeanDaoConfig = daoConfigMap.get(VeinKeyBeanDao.class).clone();
        veinKeyBeanDaoConfig.initIdentityScope(type);

        localDBTimeDao = new LocalDBTimeDao(localDBTimeDaoConfig, this);
        lockBeanDao = new LockBeanDao(lockBeanDaoConfig, this);
        lockKeyBeanDao = new LockKeyBeanDao(lockKeyBeanDaoConfig, this);
        lockKeyTempDao = new LockKeyTempDao(lockKeyTempDaoConfig, this);
        lockRecordBeanDao = new LockRecordBeanDao(lockRecordBeanDaoConfig, this);
        pwdKeyBeanDao = new PwdKeyBeanDao(pwdKeyBeanDaoConfig, this);
        userAccountDao = new UserAccountDao(userAccountDaoConfig, this);
        userBeanDao = new UserBeanDao(userBeanDaoConfig, this);
        veinKeyBeanDao = new VeinKeyBeanDao(veinKeyBeanDaoConfig, this);

        registerDao(LocalDBTime.class, localDBTimeDao);
        registerDao(LockBean.class, lockBeanDao);
        registerDao(LockKeyBean.class, lockKeyBeanDao);
        registerDao(LockKeyTemp.class, lockKeyTempDao);
        registerDao(LockRecordBean.class, lockRecordBeanDao);
        registerDao(PwdKeyBean.class, pwdKeyBeanDao);
        registerDao(UserAccount.class, userAccountDao);
        registerDao(UserBean.class, userBeanDao);
        registerDao(VeinKeyBean.class, veinKeyBeanDao);
    }
    
    public void clear() {
        localDBTimeDaoConfig.clearIdentityScope();
        lockBeanDaoConfig.clearIdentityScope();
        lockKeyBeanDaoConfig.clearIdentityScope();
        lockKeyTempDaoConfig.clearIdentityScope();
        lockRecordBeanDaoConfig.clearIdentityScope();
        pwdKeyBeanDaoConfig.clearIdentityScope();
        userAccountDaoConfig.clearIdentityScope();
        userBeanDaoConfig.clearIdentityScope();
        veinKeyBeanDaoConfig.clearIdentityScope();
    }

    public LocalDBTimeDao getLocalDBTimeDao() {
        return localDBTimeDao;
    }

    public LockBeanDao getLockBeanDao() {
        return lockBeanDao;
    }

    public LockKeyBeanDao getLockKeyBeanDao() {
        return lockKeyBeanDao;
    }

    public LockKeyTempDao getLockKeyTempDao() {
        return lockKeyTempDao;
    }

    public LockRecordBeanDao getLockRecordBeanDao() {
        return lockRecordBeanDao;
    }

    public PwdKeyBeanDao getPwdKeyBeanDao() {
        return pwdKeyBeanDao;
    }

    public UserAccountDao getUserAccountDao() {
        return userAccountDao;
    }

    public UserBeanDao getUserBeanDao() {
        return userBeanDao;
    }

    public VeinKeyBeanDao getVeinKeyBeanDao() {
        return veinKeyBeanDao;
    }

}
